<template>
  <div>
    <el-menu :default-active="activeIndex" class="el-menu-demo" mode="horizontal" @select="handleSelect"
      background-color="#545c64" text-color="#fff" active-text-color="#ffd04b">
      <el-submenu index="1" style="float: right;">
        <template slot="title">我的</template>
        <el-menu-item index="1-1">个人中心</el-menu-item>
        <el-menu-item index="1-2">退出登录</el-menu-item>
      </el-submenu>
      <el-menu-item index="2" style="float: right;">消息中心</el-menu-item>

    </el-menu>
  </div>
</template>

<script>
export default {
  data() {
    return {
      activeIndex: 1,
    }
  },
  components: {
  },

  methods: {
    handleSelect(key, keyPath) {
      console.log(key, keyPath);
    }
  }
}
</script>
